// React依赖的核心包
import React from "react"
import ReactDOM from "react-dom/client"

// 导入路由
import { RouterProvider } from "react-router-dom"
import router from "@/router/router.js"

// 导入redux仓库
import stores from "@/store/store.js"

// 导入项目的根组件
import App from "./App"
import { Provider } from "react-redux"

import "./normalize.css"

// 全局配置中文显示
import zhCN from "antd/locale/zh_CN"
import "dayjs/locale/zh-cn"
import { ConfigProvider } from "antd"

// 把App根组件渲染到id为root的根节点上
const root = ReactDOM.createRoot(document.getElementById("root"))
root.render(
  <ConfigProvider locale={zhCN}>
      <Provider store={stores}>
          <RouterProvider router={router}>
              <App />
          </RouterProvider>
      </Provider>
  </ConfigProvider>
)

